package com.quectel.core.constants;

/**
 * redis锁常量前缀
 *
 * @author caolu
 */
public class RedisLockConstants {

    /**
     * 工单日志新增过程中序列号自增加锁
     * 形式：WORK_ORDER_LOG_SEQ_INC_LOCK+"#{#dto.workOrderId}"
     */
    public static final String WORK_ORDER_LOG_SEQ_INC_LOCK =
            RedisCacheConstants.PROJECT_NAME + "WORK_ORDER_LOG_SEQ_INC_LOCK:";


    /**
     * 网格事件记录日志新增过程中序列号自增加锁
     * 形式：GRID_EVENT_RECORD_LOG_SEQ_INC_LOCK+"#{#dto.gridEventRecordId}"
     */
    public static final String GRID_EVENT_RECORD_LOG_SEQ_INC_LOCK =
            RedisCacheConstants.PROJECT_NAME + "GRID_EVENT_RECORD_LOG_SEQ_INC_LOCK:";


    /**
     * 住户锁,用于住户信息变更操作
     * 形式：HOUSEHOLD_LOCK+"#{#dto.householdId}"
     */
    public static final String HOUSEHOLD_LOCK =
            RedisCacheConstants.PROJECT_NAME + "HOUSEHOLD_LOCK:";


    /**
     * 物业账单锁,用于物业账单变更操作
     * 形式：PROPERTY_BILL_LOCK+"#{#dto.propertyBillId}"
     */
    public static final String PROPERTY_BILL_LOCK =
            RedisCacheConstants.PROJECT_NAME + "PROPERTY_BILL_LOCK:";


    /**
     * 停车月卡会员锁,用于月卡有效期变更操作
     * 形式：PARKING_CARD_LOCK+"#{#dto.villageId}_#{#dto.license}_#{#dto.licenseColor}"
     */
    public static final String PARKING_CARD_LOCK =
            RedisCacheConstants.PROJECT_NAME + "PARKING_CARD_LOCK:";

    /**
     * 停车订单锁
     * 形式：PARKING_CARD_LOCK+"#{#dto.license}_#{#dto.licenseColor}"
     */
    public static final String PARKING_ORDER_LOCK =
            RedisCacheConstants.PROJECT_NAME + "PARKING_ORDER_LOCK:";

    /**
     * 物业账单锁,用于物业账单变更操作
     * 形式：PROPERTY_CHARGEABLE_LIST_DUE_DATE_LOCK+"#{#dto.roomId}"+#{#dto.chargeableListId}
     */
    public static final String PROPERTY_CHARGEABLE_LIST_DUE_DATE_LOCK =
            RedisCacheConstants.PROJECT_NAME + "PROPERTY_CHARGEABLE_LIST_DUE_DATE_LOCK:";



    /**
     * 发帖话题
     * 形式：FORUM_TOPIC_LOCK+"#{#dto.topicId}"
     */
    public static final String FORUM_TOPIC_LOCK =
            RedisCacheConstants.PROJECT_NAME + "FORUM_TOPIC_LOCK:";


    /**
     * 帖子
     * 形式：FORUM_FORUM_LOCK+"#{#dto.forumPostId}"
     */
    public static final String FORUM_FORUM_LOCK =
            RedisCacheConstants.PROJECT_NAME + "FORUM_FORUM_LOCK:";


    /**
     * 帖子
     * 形式：FORUM_COMMENT_LOCK+"#{#dto.commentId}"
     */
    public static final String FORUM_COMMENT_LOCK =
            RedisCacheConstants.PROJECT_NAME + "FORUM_COMMENT_LOCK:";

    /**
     * 人员发帖和评论计数
     * 形式：FORUM_PERSON_COUNT_LOCK+"#{#dto.tenantId}"+":"+"#{#dto.mobileUserId}"
     */
    public static final String FORUM_PERSON_COUNT_LOCK =
            RedisCacheConstants.PROJECT_NAME + "FORUM_PERSON_COUNT_LOCK:";


    /**
     * 人员发帖和评论计数
     * 形式：FORUM_MUTE_LOCK+"#{#dto.mobileUserId}"
     */
    public static final String FORUM_MUTE_LOCK =
            RedisCacheConstants.PROJECT_NAME + "FORUM_MUTE_LOCK:";

    /**
     * 安全培训加锁
     * TRAINING_LOCK + "#{#dto.trainingId}"
     */
    public static final String TRAINING_LOCK = RedisCacheConstants.PROJECT_NAME + "TRAINING_LOCK:";

    /**
     * 党建任务
     * PARTY_BUILDING_PLAN_LOCK + "#{#dto.id}"
     */
    public static final String PARTY_BUILDING_PLAN_LOCK = RedisCacheConstants.PROJECT_NAME + "PARTY_BUILDING_PLAN_LOCK:";

    /**
     * 党建任务
     * PARTY_BUILDING_PLAN_TASK_LOCK + "#{#dto.id}"
     */
    public static final String PARTY_BUILDING_PLAN_TASK_LOCK = RedisCacheConstants.PROJECT_NAME + "PARTY_BUILDING_PLAN_TASK_LOCK:";

    /**
     * 党建调查
     * PARTY_SURVEY_LOCK + "#{#dto.id}"
     */
    public static final String PARTY_SURVEY_LOCK = RedisCacheConstants.PROJECT_NAME + "PARTY_SURVEY_LOCK:";

    /**
     * 考试锁
     * TRAINING_EXAM_LOCK + "#{#dto.examId}
     */
    public static final String TRAINING_EXAM_LOCK = RedisCacheConstants.PROJECT_NAME + "TRAINING_EXAM_LOCK:";

    /**
     * 考勤打卡锁
     * DAILY_CHECK_LOCK + "#{#dto.personId}
     */
    public static final String DAILY_CHECK_LOCK = RedisCacheConstants.PROJECT_NAME + "DAILY_CHECK_LOCK:";

    /**
     * 审核记录锁定
     * SCHEDULING_APPLY_RECORD_LOCK + "#{#dto.applyRecordId}
     */
    public static final String SCHEDULING_APPLY_RECORD_LOCK = RedisCacheConstants.PROJECT_NAME + "SCHEDULING_APPLY_RECORD_LOCK:";


    /**
     * 审核记录锁定
     * SCHEDULING_LEAVE_BALANCE_LOCK + "#{#dto.personId}
     */
    public static final String SCHEDULING_LEAVE_BALANCE_LOCK = RedisCacheConstants.PROJECT_NAME + "SCHEDULING_LEAVE_BALANCE_LOCK:";

}
